disableSerialization;

[] execvm "scripts\VTS_Functions\vtsfunctions.sqf";


// An extra comment that means nothing.


//LaserDisplay CloseDisplay 500;
CommIntercepted=false;publicVariable "CommIntercepted";
cpudialog=createDialog "RscComputer";

//Generatin tooltip
if (isnil "vtscpucontrollist") then
{
  vtscpucontrollist=[];
  _cpucfg=(missionConfigFile>>"RscComputer">>"Controls");
  _ncpucfg=(count _cpucfg)-1;  
  for "_i" from 0 to _ncpucfg do
  {
    _info=[_cpucfg select _i,"info"] call bis_fnc_returnconfigentry;
    _idc=[_cpucfg select _i,"idc"] call bis_fnc_returnconfigentry;
    if !(isnil "_info") then {vtscpucontrollist set [count vtscpucontrollist,[_idc,_info]];};
    
  }; 
};
[vtscpucontrollist] execvm "computer\cpu_generatetooltip.sqf";


if(captive user1) then
{
_display = finddisplay 8000;
_bt = _display displayctrl 10603;
_bt CtrlSetTextColor [1,0,0,1];
};

if (ShortCut != 0) then
{

_display = finddisplay 8000;
_control = _display displayctrl 101;
_details = _display displayCtrl 102;
};

// ---------------------------------------------- CONSOLE TR

console_loggedin={
choix_page=2 ;
// sleep 0.5 ;


/*
_j = 9980;
while {_j<=10055} do {
call compile format ["ctrlShow [%1,false];",_j];_j=_j+1};

_j=100;
while {_j<111} do {
call compile format ["ctrlShow [%1,false]",_j];_j=_j+1};
ctrlShow [200,false];

_j = 10056;
while {_j<=10200} do {
call compile format ["ctrlShow [%1,false];",_j];_j=_j+1};
*/

[] spawn updateradiusbuttons;

//Populate boutons
ctrlShow [10900,true];
ctrlShow [10901,true];
ctrlShow [10902,true];
ctrlShow [10903,true];
// on montre le combos command line
ctrlShow [10606,true];
ctrlShow [10300,true];

//Display button Chernarus Village & City populate
if !(ARMA2CO) then 
{
ctrlShow [10901,false];
ctrlShow [10902,false];
};

// 53 54 55 = boutons de navigation
ctrlShow [10053,true];
ctrlShow [10055,true];

// la carte
ctrlShow [105,true];

//Le bouton back to dm
if (player==user1) then {ctrlShow [19000,false];};

_j = 10200;
while {_j<=10400} do {
call compile format ["ctrlShow [%1,true];",_j];_j=_j+1};

//Initialisation des camps
_MydualList = globalcamp_side;
[10206, _MydualList] spawn Dlg_FillListBoxLists;
Unitsavewait=0;
Typesavewait=0;
Campsavewait=0;
//Initialisation des combos box
_n = [0] execVM "computer\console\boutons\console_valid_attitude.sqf";// waitUntil {scriptDone _n};
interfaceorder = [1] execVM "computer\console\boutons\console_valid_mouvement.sqf";// waitUntil {scriptDone _n};
_n = [0] execVM "computer\console\boutons\console_valid_vitesse.sqf";// waitUntil {scriptDone _n};
_n = [0] execVM "computer\console\boutons\console_valid_moral.sqf";// waitUntil {scriptDone _n};
_n = [0] execVM "computer\console\boutons\console_valid_orientation.sqf";// waitUntil {scriptDone _n};
interfaceformation = [1] execVM "computer\console\boutons\console_valid_formation.sqf";// waitUntil {scriptDone _n};
_n = [1] execVM "computer\console\boutons\joueur_tp.sqf";// waitUntil {scriptDone _n};
_n = [0] execVM "computer\console\boutons\script_commande.sqf";// waitUntil {scriptDone _n};
_n = [1] execVM "computer\console\boutons\console_valid_music.sqf";// waitUntil {scriptDone _n};
_n = [1] execVM "computer\console\boutons\console_valid_audio_env.sqf";// waitUntil {scriptDone _n};
_n = [1] execVM "computer\console\boutons\console_valid_colors.sqf";// waitUntil {scriptDone _n};
_n = [1] execVM "computer\console\boutons\console_valid_pre_com_line.sqf";// waitUntil {scriptDone _n};
_n = [1] execVM "computer\console\boutons\console_valid_pre_init_line.sqf";// waitUntil {scriptDone _n};
_n = [1] execVM "computer\console\boutons\console_valid_arty.sqf";// waitUntil {scriptDone _n};
_n = [0] execVM "computer\boutons\pluie_action.sqf";// waitUntil {scriptDone _n};
_n = [0] execVM "computer\boutons\brume_action.sqf";// waitUntil {scriptDone _n};
_n = [0] execVM "computer\boutons\heure_action.sqf";// waitUntil {scriptDone _n};



/*
_n = [] execVM "computer\console\boutons\l4_type_act1.sqf"; waitUntil {scriptDone _n};
_n = [] execVM "computer\console\boutons\l3_delai_act1.sqf"; waitUntil {scriptDone _n};
_n = [] execVM "computer\console\boutons\l2_qui_act1.sqf"; waitUntil {scriptDone _n};
_n = [] execVM "computer\console\boutons\l2_combien_act1.sqf"; waitUntil {scriptDone _n};
_n = [] execVM "computer\console\boutons\l2_quoi_act1.sqf"; waitUntil {scriptDone _n};
_n = [] execVM "computer\console\boutons\l1_ellipse1.sqf"; waitUntil {scriptDone _n};
*/

_n = [1] execVM "computer\console\boutons\joueursolo_telep.sqf";// waitUntil {scriptDone _n};
_n = [0] execVM "computer\console\boutons\console_joueur_scripteur.sqf";// waitUntil {scriptDone _n};

[] call Dlg_RestoreParams;


};

// ---------------------------------------------- On s'occupe de la page d'accueil

if (ShortCut == 0) then
{
  ctrlShow [100,false];
	ctrlShow [101,false];

  [] call console_loggedin;
};





if (true) exitWith {};
